/*
 * @message: 描述
 * @Author: Roy
 * @Email: cx_love_xc@163.com
 * @Github: cx_love_xc@163.com
 * @Date: 2022-01-12 15:58:51
 * @LastEditors: Roy
 * @LastEditTime: 2022-01-16 18:02:37
 * @Deprecated: 否
 * @FilePath: /blog/src/front/container/component/footer/index.jsx
 */
import React from 'react'
import styles from './index.module.scss'

const Footer = ({ schema }) => {
    const { attributes = {}, children = [] } = schema;
    const { copyright, record } = attributes;
    return (
        <div className="wrapper">
            <div className={styles.footer}>
                <ul className={styles.list}>
                    {
                        children.map((item, index) => {
                            const { attributes = {} } = item;
                            const { title, link } = attributes;
                            return <li className={styles.item} key={index}>
                                <a className={styles.link} href={link} target="_blank" rel="noreferrer">{title}</a>
                            </li>
                        })
                    }
                </ul>
                <div className={styles.copyright}>
                    {copyright} {record}
                    {/* Greedy Cat | Copyright © 2020-present */}
                </div>
            </div>
        </div>
    );
}

export default Footer;